<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/extras/spring-security">
<head>
    <meta charset="UTF-8">
    <title>Student</title>
    <link th:href="@{/css/bootstrap.min.css}" href="../static/css/bootstrap.min.css" rel="stylesheet">
    <link th:href="@{/css/flat-ui.css}" href="../static/css/flat-ui.css" rel="stylesheet">
    <link th:href="@{/css/signin.css}" href="../static/css/signin.css" rel="stylesheet">

    <title>Git</title>
</head>
<body>
<div th:include="s-head :: s-head"></div>

<br><br><br><br>
<div class="container">
    <!-- Main component for a primary marketing message or call to action -->
        <div th:if="${flag == '1'}">

        <div class="jumbotron">
        <form action="/student/gitproject" method="post" th:action="@{/student/gitproject}">
        <table class="table table-bordered">
            <caption>项目信息</caption>
            <tr>
                <td>项目名称</td>
                <td th:text="${pro.getName()}"></td>
            </tr>
            <tr>
                <td>项目描述</td>
                <td th:text="${pro.getDescription()}"></td>
            </tr>
            <tr>
                <td>ssh地址</td>
                <td th:text="${pro.getSshUrlToRepo()}"></td>
            </tr>
        </table>
            <button class="btn btn-danger" type="submit" >删除项目</button>
        </form>

            <!--<div class="jumbotron">-->

                <table class="table table-bordered">
                    <caption>提交记录</caption>
                    <tr>
                        <td>CommittedDate</td>
                        <td>Message</td>
                        <td>CommitterName</td>
                    </tr>
                    <tr th:each="commits:${commit}">
                        <td th:text="${commits.getCommittedDate()}"></td>
                        <td th:text="${commits.getMessage()}"></td>
                        <td th:text="${commits.getCommitterName()}"></td>
                    </tr>

                </table>

            <!--</div>-->

        </div>
        </div>

        <div th:if="${flag == '0'}">
            <div class="jumbotron">
            <h4>项目不存在</h4>
            </div>
        </div>


</div> <!-- /container -->




<script th:src="@{/js/bootstrap.min.js}" src="../static/js/bootstrap.min.js"></script>
<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<script th:src="@{/js/jquery-3.1.1.min.js}" src="../static/js/jquery-3.1.1.min.js"></script>
<!-- Include all compiled plugins (below), or include individual files as needed -->
<script th:src="@{/js/flat-ui.min.js}" src="../static/js/flat-ui.min.js"></script>

<script th:src="@{/js/application.js}" src="../static/js/application.js"></script>

</body>
</html>